import request from '@/config/axios'

// 代码检查 VO
export interface infraLlmReviewVO {
  id: number // 编号
  cnt: string // 内容
  mark: string // 描述
  delFlag: number // 删除
  result: string // 检查结果
}

// 代码检查 API
export const infraLlmReviewApi = {
  // 查询代码检查分页
  getinfraLlmReviewPage: async (params: any) => {
    return await request.get({ url: `/infra/infra-llm-review/page`, params })
  },

  // 查询代码检查详情
  getinfraLlmReview: async (id: number) => {
    return await request.get({ url: `/infra/infra-llm-review/get?id=` + id })
  },

  // 新增代码检查
  createinfraLlmReview: async (data: infraLlmReviewVO) => {
    return await request.post({ url: `/infra/infra-llm-review/create`, data })
  },

  // 修改代码检查
  updateinfraLlmReview: async (data: infraLlmReviewVO) => {
    return await request.put({ url: `/infra/infra-llm-review/update`, data })
  },

  // 删除代码检查
  deleteinfraLlmReview: async (id: number) => {
    return await request.delete({ url: `/infra/infra-llm-review/delete?id=` + id })
  },

  // 导出代码检查 Excel
  exportinfraLlmReview: async (params) => {
    return await request.download({ url: `/infra/infra-llm-review/export-excel`, params })
  }
}